package br.com.kapa.stubs;

public class ClienteBeanProxy implements br.com.kapa.stubs.ClienteBean {
  private String _endpoint = null;
  private br.com.kapa.stubs.ClienteBean clienteBean = null;
  
  public ClienteBeanProxy() {
    _initClienteBeanProxy();
  }
  
  public ClienteBeanProxy(String endpoint) {
    _endpoint = endpoint;
    _initClienteBeanProxy();
  }
  
  private void _initClienteBeanProxy() {
    try {
      clienteBean = (new br.com.kapa.stubs.ClienteBeanServiceLocator()).getClienteBeanPort();
      if (clienteBean != null) {
        if (_endpoint != null)
          ((javax.xml.rpc.Stub)clienteBean)._setProperty("javax.xml.rpc.service.endpoint.address", _endpoint);
        else
          _endpoint = (String)((javax.xml.rpc.Stub)clienteBean)._getProperty("javax.xml.rpc.service.endpoint.address");
      }
      
    }
    catch (javax.xml.rpc.ServiceException serviceException) {}
  }
  
  public String getEndpoint() {
    return _endpoint;
  }
  
  public void setEndpoint(String endpoint) {
    _endpoint = endpoint;
    if (clienteBean != null)
      ((javax.xml.rpc.Stub)clienteBean)._setProperty("javax.xml.rpc.service.endpoint.address", _endpoint);
    
  }
  
  public br.com.kapa.stubs.ClienteBean getClienteBean() {
    if (clienteBean == null)
      _initClienteBeanProxy();
    return clienteBean;
  }
  
  public br.com.kapa.stubs.Cliente consultaCliente(java.lang.String arg0) throws java.rmi.RemoteException{
    if (clienteBean == null)
      _initClienteBeanProxy();
    return clienteBean.consultaCliente(arg0);
  }
  
  public java.lang.String helloworld() throws java.rmi.RemoteException{
    if (clienteBean == null)
      _initClienteBeanProxy();
    return clienteBean.helloworld();
  }
  
  
}